/*
 * @Author: 徐建辰
 * @Date: 2022-02-12 17:37:13
 * @LastEditTime: 2022-02-14 16:21:32
 * @LastEditors: 徐建辰
 * @Description: 用户模块请求处理
 */
import request from './request'

// 登录
export const login = data => request({
  method: 'post',
  url: '/user/login',
  data
})

// 注册
export const register = data => request({
  method: 'post',
  url: '/user/register',
  data
})

// 获取用户信息
export const getUserInfo = () => request({url: '/user/info'})

// 编辑个人信息
export const editUserInfo = params => request.put('/user/info', params)

// 退出登录
export const logout = () => request.post('/user/logout')